package com.spring.framework.webmvc.servlet;

import java.util.HashMap;
import java.util.Map;

/**
 * @author ππ
 * @date 2020-11-17 13:58
 * @desc 声明ModelAndView
 */

public class MyModelAndView {
    private String viewName;
    private Map<String,?> model = new HashMap<>();

    public MyModelAndView(String viewName) {
        this.viewName = viewName;
    }

    public MyModelAndView(String viewName, Map<String, ?> model) {
        this.viewName = viewName;
        this.model = model;
    }

    public String getViewName() {
        return viewName;
    }

    public void setViewName(String viewName) {
        this.viewName = viewName;
    }

    public Map<String, ?> getModel() {
        return model;
    }

    public void setModel(Map<String, ?> model) {
        this.model = model;
    }
}
